from django.conf.urls.defaults import *
from django.views.generic.list_detail import object_list

from orangeademusic.news.models import Post

news_list = {
	'queryset': Post.objects.all().order_by('-date'),
	
	'allow_empty':True,
	'template_name':'news.html',
	'template_object_name':'post',
	'paginate_by':2,
}

urlpatterns = patterns('',
	(r'$', object_list, news_list),
	# Meme pas besoin des pages? Ca a l'air de fonctionner sans...
	#(r'page(?P<page>[0-9]+)/$', object_list, news_list),
)